<script setup lang="ts">
import {getFileDate} from "@/config/utils/get-file-to-tabel";
import {getContentDirTree} from "@/config";
import LoadingOne from "@/components/communal/Loading/loading-one.vue";
import Calculator from "@/components/utils/Tools/calculator.vue";
import CardAuthorInfo from "@/components/communal/Card/card-author-info.vue";
import {ref} from "vue";
const fileUpdete = (param:any,param1:any):void => {
  const {file} =param
  const res = getFileDate(file)
}
let srt = `<h1>一级标题1</h1>
<h2>二级标题1</h2>
<h3>三级标题1</h3>
<h1>一级标题2</h1>
<h2>二级标题2</h2>
<h1>一级标题3</h1>
`
import type { TreeProps } from 'ant-design-vue';
const treeData:TreeProps['treeData'] = getContentDirTree(srt)
const expandedKeys = ref<string[]>(treeData.map((item:any)=>item.key));
const selectedKeys = ref<string[]>([]);
</script>

<template>
  <div style="background: #f2f2f2;width:300px;height: 300px;" >
    <CardAuthorInfo width="240px" height="270px" cover="http://localhost:5173/linter/src/views/system/About/image/index02.png"></CardAuthorInfo>
  </div>

  <calculator></calculator>
<!--  <div class="t-div">-->
<!--    <a-upload-->
<!--        :customRequest="fileUpdete"-->
<!--    >-->
<!--      <a-button>上传文件</a-button>-->
<!--    </a-upload>-->
<!--  </div>-->
<!--  <div style="position: relative;width: 300px;height: 300px">-->
<!--    <LoadingOne :loading="true"></LoadingOne>-->
<!--  </div>-->
<!--  <a-directory-tree-->
<!--      v-model:expandedKeys="expandedKeys"-->
<!--      v-model:selectedKeys="selectedKeys"-->
<!--      multiple-->
<!--      :tree-data="treeData"-->
<!--  ></a-directory-tree>-->
</template>

<style scoped lang="css">
.t-div{
  padding: 100px;
  width: 800px;
  height: 200px;
  background: #0d9488;
}
</style>